<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"><head>
<title>管理中心</title>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<link href="/sys-admin/css/general.css" rel="stylesheet" type="text/css">
<link href="/sys-admin/css/main.css" rel="stylesheet" type="text/css">
<script src="/sys-admin/js/jquery.js" type="text/javascript"></script>
<script src="/sys-admin/js/cn_message.js" type="text/javascript"></script>
<script src="/sys-admin/js/validate.js" type="text/javascript"></script>
</head>
<body>
<h1><span class="action-span1">分类频道修改</span></h1>
<div class="list-div">
<form action="/sys-admin/action/cms/channel.php" method="post">
<input type="hidden" name="met" value="editcategory"/>
<input type="hidden" name="id" value="<{$channel.channel_id}>"/>
<table>
 <tr>
    <td class="label"><span class="require-field">*</span>名称</td>
    <td><input type="text" name="name"  value="<{$channel.channel_name}>" maxlength="30" size="20" id="c_name"/></td>
 </tr>
 <tr>
    <td class="label">分类</td>
    <td><{$channel.cat_name}></td>
</td>
 </tr>
 <tr>
    <td class="label"><span class="require-field">*</span>模板</td>
    <td> <select name="tpid"  id="sel_tp_id">
		<option value="0">--选择模板--</option>
		<{foreach from=$templates item=template}>
			<option value="<{$template.tp_id}>" <{if $template.tp_id eq $channel.tp_id}>selected="selected"<{/if}>><{$template.tp_name}></option>
		<{/foreach}> 
		</select>
	</td>
 </tr>
   <tr>
    <td class="label">标题</td>
    <td><textarea rows="3" cols="40" name="title"><{$channel.page_title}></textarea></td>
 </tr>
  <tr>
    <td class="label">关键字</td>
    <td><textarea rows="3" cols="40" name="key"><{$channel.page_keywords}></textarea></td>
 </tr>
  <tr>
    <td class="label">描述</td>
    <td><textarea rows="3" cols="40" name="desc"><{$channel.page_desc}></textarea></td>
 </tr>
 <tr>
    <td class="label"></td>
    <td><input type="submit" value="修改" class="button" onclick="return editCategoryChannel();"/>&nbsp;&nbsp;&nbsp;</td>
</tr>
</table>
</form>
</div>
<script type="text/javascript">
function editCategoryChannel(){
	if(!Fun.isEmpty($('#c_name'))){
		alert('名称不能为空');
		return false;
	}
	if($('#sel_tp_id').val()=='' || parseInt($('#sel_tp_id').val()) < 1){
		alert('请选择模板');
		return false;
	}
	return true;
}
</script>
</body></html>